
# 查找最新的一个文件
my_dir="/usr/mcc/update";
SHORT_NAME="mcc-smp-web-service";
NAME_PATTERN="*$SHORT_NAME.*";
TARGET_FILE=$(find $my_dir -name "$NAME_PATTERN" |xargs ls -alt| head -n 1 | awk '{print $9}' );
echo "$TARGET_FILE";

TARGET_FILE=$(find /usr/mcc/update -name "*.mcc-smp-web-service.*" |xargs ls -alt| head -n 1 | awk '{print $9}' );
echo $TARGET_FILE;

echo $(find /usr/mcc/update -name "*.mcc-smp-web-service.*" |xargs ls -alt| head -n 1 | awk '{print $9}' );

